package js.web.center.web;

import org.eclipse.jetty.websocket.server.WebSocketHandler;
import org.eclipse.jetty.websocket.servlet.WebSocketServletFactory;
/**
 * 
 * @author dowell
 *
 */
public class JsWebSocketChangeHandler extends WebSocketHandler {
	private static long outTime=10*60*1000;
	private static long writeOutime=10*1000;
	@Override
	public void configure(WebSocketServletFactory webSocketServletFactory) {
		webSocketServletFactory.getPolicy().setIdleTimeout(outTime);
		webSocketServletFactory.getPolicy().setAsyncWriteTimeout(writeOutime);
		webSocketServletFactory.setCreator(new JsWebWebSocketCreator());
	}
}
